#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>

int Count(int m, int n)
{
    int i = 0;
    int diff = m ^ n;//1说明该位m ，n不同
    int count = 0;
    while (i < 32)
    {
        if ((diff >> i) & 1)
        {
            count++;
        }
        i++;
    }
    return count;
}
int main()
{
    int m = 0;
    int n = 0;
    scanf("%d%d", &m, &n);
    int ret = Count(m, n);
    printf("%d", ret);
    return 0;
}

/*00000000000000000000000000010110    22的原码
00000000000000000000000000000000
00000000000000000000000000100001    33的原码
00000000000000000000000000000000
count = 1
00001011   11
00010000   16
count  = 2
00000101   5
00001000   8
count = 3
00000010   2
00000100   4
count = 4
00000001   1
00000010   2
count = 5
00000000   0
00000001   1
count = 6
00000000
00000000

00000000000000000000000010111100
00000000000000000000000000000000
00000000000000000000000001001101
00000000000000000000000000000000
*/